import { request } from '@umijs/max';

export const getIssueListApi =(params)=>{
    return request('/api/issue',{
        method:"GET",
        params:{...params}
    })
}

// 根据id请求问答详情
export const getIssueById = (id)=>{
    return request(`/api/issue/${id}`)
}

export const editIssueStutasApi = (id,tar)=>{
    return request(`/api/issue/${id}`,{
        method:'PATCH',
        data:tar
    })
}
// 删除问答
export const  deleteIssueApi = (id)=>{
    return request(`/api/issue/${id}`,{
        method:'DELETE'
    })
}